b8e59d0cb4041d5a6fefe72686c8487ba977ac54,src/org/jgroups/jmx/ResourceDMBean.java,ResourceDMBean,exposeManagedAttribute,#Method#,227
Before Change
attributeName=(attributeName==null)?methodName.substring(3):attributeName;
info=new MBeanAttributeInfo(attributeName,
method.getParameterTypes()[0].getCanonicalName(),
attr.description(),
true,
true,
false);
After Change
return;
}
ManagedAttribute attr = method.getAnnotation(ManagedAttribute.class);
Property prop=method.getAnnotation(Property.class);
boolean expose_prop=prop != null && prop.exposeAsManagedAttribute();
boolean expose=attr != null || expose_prop;
if(!expose)
return;
// Is name field of @ManagedAttributed used?
String attributeName=attr != null? attr.name() : null;
if(attributeName != null && attributeName.trim().length() > 0)
attributeName=attributeName.trim();
else
attributeName=null;
String descr=attr != null ? attr.description() : prop != null? prop.description() : null;
boolean writeAttribute=false;
MBeanAttributeInfo info=null;